/* Reset básico e estilos globais */ * { margin: 0; padding: 0; box-sizing: border-box; } body { font-family: Arial, sans-serif; line-height: 1.6; height: 100vh; /* Altura total da viewport para layout sticky */ display: flex; flex-direction: column; /* Corpo como coluna para header, container e footer */ } /* Header */ .header { background-color: #333; color: white; padding: 1rem; display: flex; justify-content: space-between; /* Logo à esquerda, nav à direita */ align-items: center; } .header h1 { font-size: 1.5rem; } .header nav { display: flex; gap: 1rem; } .header a { color: white; text-decoration: none; } /* Container principal (usando Flexbox para sidebar e main) */ .container { display: flex; /* Flexbox ativado */ flex: 1; /* Ocupa o espaço restante entre header e footer */ flex-direction: row; /* Itens lado a lado */ } .sidebar { background-color: #f4f4f4; padding: 1rem; width: 250px; /* Largura fixa para sidebar */ flex-shrink: 0; /* Não encolhe */ } .main { background-color: #fff; padding: 1rem; flex: 1; /* Ocupa o espaço restante */ } /* Footer */ .footer { background-color: #333; color: white; text-align: center; padding: 1rem; } /* Responsividade: Em telas pequenas, empilha sidebar e main verticalmente */ @media (max-width: 768px) { .container { flex-direction: column; /* Muda para coluna */ } .sidebar { width: 100%; /* Largura total em mobile */ } }